package cool.webstudy.admin.controller.flag;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import cool.webstudy.admin.model.dto.competition.PaginationQueryCompetitionInfoListDTO;
import cool.webstudy.admin.model.dto.flag.CommitFlagDTO;
import cool.webstudy.admin.model.vo.competition.PaginationQueryCompetitionInfoListVO;
import cool.webstudy.admin.service.DynamicFlagService;
import cool.webstudy.admin.utils.aspect.request.RequestParameterCheck;
import cool.webstudy.admin.utils.common.Result;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 莫振双
 * @date 2025/4/6 17:26
 * @description: flag服务接口
 */
@Tag(name = "flag服务")
@RestController
@RequestMapping("/flag")
@RequestParameterCheck
public class FlagController {
    @Autowired
    private DynamicFlagService dynamicFlagService;
    @PostMapping("/commit")
    @Operation(summary = "提交flag接口")
    public Result commit(@RequestBody CommitFlagDTO dto){
        dynamicFlagService.commitFlag(dto);
        return Result.success();
    }
}
